#!/bin/bash
read -p '请输入你要查询的姓名' sname
read -s -p '请输入数据库用户' user
echo -e "\n"
sql="select * from test.user where username='${sname}';"
mysql -u${user} -p -e "${sql}"
exit